<template>
	<view class="musi-header">
		<view class="music-head-icon" v-if="icon">
			<text class="iconfont icon-zuojiantou" @click="handleToBack()"></text>
			|
			<text class="iconfont icon-shouye"  @click="handleToHome()"></text>

		</view>

		{{title}}


	</view>
</template>

<script>
	export default {
		name: "musichead",
		data() {
			return {

			};
		},
		props: ["title","icon"],
		methods:{
			handleToBack(){
				uni.navigateBack()
			},
			handleToHome(){
				uni.navigateTo({
					url:'../../pages/index/index'
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.musi-header {
		width: 100%;
		height: 75px;
		position: relative;
		text-align: center;
		line-height: 75px;

		.music-head-icon {
			position: absolute;
			width: 90px;
			height: 30px;
			top: 27px;
			left: 10px;
			line-height: 30px;
			display: flex;
			background-color: rgba(0, 0, 0, 0.3);
			border-radius: 15px;
			justify-content: space-around;

			.iconfont {
				color: white;
			}
		}

		.head-title {
			font-size: 14px;
			// color: white;
			// position: absolute;
			// right: ;
		}

	}
</style>
